<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<%@include file="/common/common.jspf" %>
<script type="text/javascript" src="${ctx}/js/hr/staff_edit.js"></script>
<style type="text/css">
.col-sm-3 {
	width: 15%;
	float: left;
}

.col-sm-9 {
	width: 85%;
	float: left;
}
label[class^="btn btn-default"]{
	margin-top: -4px;
}
</style>
<script type="text/javascript" src="${ctx}/js/jedate/jedate.js"></script>
</head>
<body>
	<div class="l_err" style="width: 100%; margin-top: 2px;"></div>
	<form id="form" name="form" class="form-horizontal" method="post"
		action="${ctx}/hrstaff/staff_editEntity.shtml">
		<input type="hidden" class="form-control checkacc" value="${staff.id}"
			name="staffFormMap.id" id="id">
		<section class="panel panel-default">
			<div class="panel-body">
			<div class="form-group">
				<label class="col-sm-3 control-label">工号</label>
				<div class="col-sm-9">
					<input type="text" class="form-control " required
						 name="staffFormMap.job_number" value="${staff.job_number}" readonly="true">
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">姓名</label>
				<div class="col-sm-9">
					<input type="text" class="form-control " required
						placeholder="请输入姓名" name="staffFormMap.name" value="${staff.name}">
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">职务</label>
				<div class="col-sm-9">
					<select style="width: 20%;" class="form-control" id="salesman"
						name="staffFormMap.position_id">
						<c:forEach var="key" items="${duty}">
							<option value="${key.id }" ${staff.position_id==key.id ? 'selected':'' }>${key.position_name }</option>
						</c:forEach>
					</select>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">性别</label>
				<div class="col-sm-9">
					<select style="width: 15%;" class="form-control" id="salesman"
						name="staffFormMap.sex">
						<option value="1" ${staff.sex==1?'selected':''}>男</option>
						<option value="2" ${staff.sex==2?'selected':''}>女</option>
					</select>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">电话号码</label>
				<div class="col-sm-9">
					<input type="text" class="form-control " required
						placeholder="请输入电话号码" name="staffFormMap.phone" value="${staff.phone}">
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">住址</label>
				<div class="col-sm-9">
					<input type="text" class="form-control " required
						placeholder="请输入住址" name="staffFormMap.address" value="${staff.address}">
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">身份证号码</label>
				<div class="col-sm-9">
					<input type="text" class="form-control " required
						placeholder="请输入身份证号码" name="staffFormMap.IdCard" value="${staff.IdCard}">
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">第一次入厂日期</label>
				<div class="col-sm-9">
					<input type="text" class="form-control " required 
						 name="staffFormMap.first_entry" value="${staff.first_entry}" readonly="true" >
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">社保</label>
				<div class="col-sm-9">
					<select style="width: 15%;" class="form-control" id="salesman"
						name="staffFormMap.social_security">
						<option value="1" ${staff.social_security==1?'selected':''}>已购买</option>
						<option value="2" ${staff.social_security==2?'selected':''}>未购买</option>
					</select>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">介绍人</label>
				<div class="col-sm-9">
					<input type="text" class="form-control " required
						placeholder="请输入介绍人" name="staffFormMap.introducer" value="${staff.introducer}">
				</div>
			</div>
				<div class="line line-dashed line-lg pull-in"></div>
			</div>
			<footer class="panel-footer text-right bg-light lter">
			<button type="submit" class="btn btn-success btn-s-xs">提交</button>
		</footer> 
	</section>
	</form>
	<script type="text/javascript" src="${ctx}/js/jedate/jedate.js"></script>
<script type="text/javascript">
jeDate({
	dateCell:"#one",
	format:"YYYY-MM-DD hh:mm:ss",
	isinitVal:false,
	isTime:true, 
	isClear:false,
	minDate:"2014-09-19 00:00:00"
})

</script>
</body>
</html>